package com.quick.im.common.entity.message;


import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.concurrent.ScheduledFuture;

@Builder
@Data
@AllArgsConstructor
@NoArgsConstructor
public class MessageInfo {

    /**
     * 1-person to person(1对1聊天) 2-group(群聊) 3-heartbeat(心跳消息)
     */
    private String messageType;
    /**
     *  关系ID
     */
    private String relationshipId;

    /**
     * 1-text(文字) 2-image(图片) 3-short voice(短语音 <60s) 4-short videos(短视频 <30s)
     */
    private String messageContentType;

    /**
     * 消息内容
     */
    private String content;
    /**
     * 消息id
     */
    private String messageId;

    /**
     * 消息发送时间
     */
    private String sendTime;
    /**
     * 消息发送人
     */
    private String sendUid;
    /**
     * 消息接收人
     */
    private String receiveUid;

    private Integer retryCount ;

    private ScheduledFuture<?> future;

    public int incrementRetryCount() {
        return ++retryCount;
    }



}
